function[]=classify(fn)
arguments 
  fn string = "car.pcd"
end

load("model.mat","parameters","state","classes")
ptCloud = pcread(fn);
X = preprocessPointCloud(ptCloud);
dlX = dlarray(X{1},"SCSB");
YPred = pointnetClassifier(dlX,parameters,state,false);
[~,classIdx] = max(YPred,[],1);
figure
pcshow(ptCloud.Location,[0 1 0],"MarkerSize",40,"VerticalAxisDir","down")
title(classes(classIdx))
